namespace java net.ulrice.mdls.sensor.facade

struct CpuInfo {
	1: string processor,
	2: string vendorId,
	3: string cpuFamily,
	4: string model,
	5: string modelName,
	6: string stepping,
	7: string microcode,
	8: string cpuMhz,
	9: string cacheSize,
	10: string physicalId,
	11: string siblings,
	12: string coreId,
	13: string cpuCores,
	14: string apicId,
	15: string initialApicId,
	16: string fpu,
	17: string fpuException,
	18: string cpuIdLevel,
	19: string wp,
	20: string flags,
	21: string bogomips,
	22: string clFlushSize,
	23: string cacheAlignment,
	24: string addressSized,
	25: string powerManagement;
}

struct CpuLoad {
	1: string cpuId,
	2: string cpuName,
	3: double user,
	4: double nice,
	5: double system,
	6: double idle,
	7: double iowait,
	8: double irq,
	9: double softIrq,
	10: double total;
}

struct MemoryInfo {
	1: i64 totalMemory,
	2: i64 freeMemory,
	3: i64 usedMemory,
	4: double usedMemoryPercentage,
	5: i64 totalSwap,
	6: i64 freeSwap,
	7: i64 usedSwap,
	8: double usedSwapPercentage;
}

struct NetworkInfo {
	1: string interfaceName,
	2: i64 bytesSend,
	3: i64 bytesReceived,
	4: double bytesSendPerSecond,
	5: double bytesReceivedPerSecond;
}

service SensorService {
	i32 getNumCores(),
	list<CpuInfo> getCpuInfo(),
	list<CpuLoad> getCpuLoad(),
	list<NetworkInfo> getNetworkInfo(),
	MemoryInfo getMemoryInfo();
}
